package com.john.bluetoothtest2.User_Info;

import android.content.Context;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;

public class userDB extends SQLiteOpenHelper {

    public userDB(Context context){
        super(context,"user_account.db",null,1);
    }
    @Override
    public void onCreate(SQLiteDatabase sqLiteDatabase) {
        String sql = "CREATE TABLE user_account(\n" +
                "_id INTEGER PRIMARY KEY autoincrement,\n" +
                "phone VARCHAR(15) DEFAULT NULL,\n" +
                "password VARCHAR(15) DEFAULT NULL" + " )";
        sqLiteDatabase.execSQL(sql);
        String sql2 = "insert into user_account values(1,'18039374796','111111')";
        sqLiteDatabase.execSQL(sql2);
    }

    @Override
    public void onUpgrade(SQLiteDatabase sqLiteDatabase, int i, int i1) {

    }
}
